Summary
A networkable dictionary for use with the
SyncAttribute and
HostSyncAttribute. Only changes will be
networked instead of sending the whole dictionary every time, so it's more efficient.
['br']['b']
public class MyComponent : Component
{
[Sync] public NetDictionary<string,bool> MyBoolTable { get; set; } = new();
['br']
public void SetBoolState( string key, bool state )
{
if ( IsProxy ) return;
MyBoolTable[key] = state;
}
}
Constructors
Properties
Count |
<inheritdoc cref="P:System.Collections.ObjectModel.ObservableDictionary`2.Count" /> |
Item |
|
Keys |
<inheritdoc cref="P:System.Collections.ObjectModel.ObservableDictionary`2.Keys" /> |
Values |
<inheritdoc cref="P:System.Collections.ObjectModel.ObservableDictionary`2.Values" /> |
Methods